package com.heima.bos.service;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.heima.bos.dao.impl.BaseDaoImpl;
import com.heima.bos.dao.impl.StaffDao;
import com.heima.bos.domain.Staff;
@Transactional
@Service
public class StaffService extends BaseService<Staff> {
	@Resource
	private StaffDao staffDao;
	@Override
	public BaseDaoImpl<Staff> getDao() {
		return staffDao;
	}
	/**
	 * 批量作废取派员
	 * @param ids
	 */
	public void batchCancel(String ids) {
		staffDao.batchCancel(ids);
	}
	public void test(Staff entity) {
		String id = entity.getId();
		Staff staff = staffDao.findById(id);
		staff.setName(entity.getName());
		staff.setTelephone(entity.getTelephone());
		staff.setStation(entity.getStation());
		staff.setHaspda(entity.getHaspda());
		staff.setDeltag(entity.getDeltag());
		staff.setStandard(entity.getStandard());
		
	}
	

}
